<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>3D 导航</title>
  <style>

    ul {
      width: 500px;
      height: 30px;
      list-style-type: none;
      padding: 0;
      margin: 200px auto;
    }

    ul li {
      width: 100px;
      height: 30px;
      text-align: center;
      line-height: 30px;
      font-size: 18px;
      float: left;
      transition: .5s;

      position: relative;
      transform-style: preserve-3d;
    }

    ul li:hover {
      transform: rotateX(-90deg);
    }

    li span {
      position: absolute;
      left: 0;
      top: 0;
      width: 100%;
      height: 100%;
    }

    li span:first-child {
      background-color: pink;

      transform: rotateX(90deg) translateZ(15px);
    }

    li span:last-child {
      background-color: red;
    }
  </style>
</head>
<body>
  <ul>
    <li>
      <span>首页</span>
      <span>Index</span>
    </li>
    <li>
      <span>订单</span>
      <span>Order</span>
    </li>
    <li>
      <span>购物车</span>
      <span>Cart</span>
    </li>
    <li>
      <span>登录</span>
      <span>Login</span>
    </li>
    <li>
      <span>注册</span>
      <span>Register</span>
    </li>
  </ul>
</body>
</html>